<?php
    class Form_adquiciciones extends Zend_Form {
        
        
        public function init () {
            $controller = Zend_Controller_Front::getInstance();
            
            $name = $this->createElement('text', 'name');
            $name->addFilter('StringTrim');
            $name->setRequired(TRUE);
            $name->setAttribs(array('class'=>'inputStyle','maxlength'=>'80','order'=>1));
            $name->addErrorMessage("Por favor ingrese el nombre.");
            $this->addElement($name);
            
            $detalle = $this->createElement('textarea', 'detalle');
            $detalle->addFilter('StringTrim');
            $detalle->setAttribs(array('class'=>'inputStyle','maxlength'=>'80','order'=>1));
            $detalle->setAttrib('rows', '4');
            $detalle->setAttrib('cols', '60');
            $this->addElement($detalle);
            
            $hidden = $this->createElement('hidden', 'hiddenedit');
            $hidden->setValue("none");
            $this->addElement($hidden);
            
            $BtnCancel = $this->createElement('reset', 'BtnCancel');
            $BtnCancel->setAttribs(array('order'=>6,'class'=>"listStyle", 'onclick'=>'clearForm();'));
            $BtnCancel->setLabel('Cancelar');
            $this->addElement($BtnCancel);
            
            $BtnGuardar = $this->createElement('submit', 'BtnGuardar');
            $BtnGuardar->setAttribs(array('order'=>8,'class'=>"listStyle"));
            $BtnGuardar->setLabel('Guardar');
            $this->addElement($BtnGuardar);
            
            $this->setElementDecorators(array(
                array('ViewHelper'),
                array('Errors'),
            ));
        }
    }
?>